FROM newhub.fadongxi.com/library/openjdk8-skywalking
#虚拟机内存变量
ENV JAVA_OPTS=$JAVA_OPTS
#skywalking应用名及服务地址配置。（-e SW_PARAMS=agent.service_name=xxx,collector.backend_service=ip:port）
ENV SW_PARAMS=$SW_PARAMS

#编译后的jar包copy到容器中创建到目录内
COPY target/channel-server.jar /usr/local/channel-server.jar
COPY src/main/resources/base/entrypoint.sh /usr/local/entrypoint.sh
RUN chmod +x /usr/local/entrypoint.sh
WORKDIR /usr/local

#指定容器启动时要执行的命令
ENTRYPOINT ["/usr/local/entrypoint.sh"]